package com.example.demo.customer;

import com.fasterxml.jackson.annotation.JsonProperty;

import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.Table;


@Entity
@Table
public class Customer {
    @Id
    private  Long id;
    private  String email;
    private  String name;
    @JsonProperty(access = JsonProperty.Access.WRITE_ONLY)
    private  String password ;
    public Long getId() {
        return id;
    }

    public String getEmail() {
        return email;
    }

    public String getName() {
        return name;
    }

    public String getPassword() {
        return password;
    }

    public Customer(){

    }
    public Customer(Long id, String name,String password) {
        this.id = id;
        this.name = name;
        this.password =password;
        this.email = email;
    }


    @Override
    public String toString() {
        return "Customer{" +
                "id=" + id +
                ", name='" + name + '\'' +
                '}';
    }
}
